<?php
/**
* lobby config
*/

if(ifLobby())
{
	
	if($_SERVER['PHP_SELF'] != "/fds/ajax/order.php ")
	{
		die("You cannot acces this page.");
	}
}

function ifLobby()
{
	$_sql = "select settings_value from settings where id = '2'";
	$_res = mysql_query($_sql);
	list($val)=mysql_fetch_row($_res);
	$room =($_GET["roomid"]) ? $_GET["roomid"] : $_POST["roomid"];

	if($room==$val)
	{
		return true;
	}

	return false;
}
?>